package com.example.toolbar.toolbar;

import android.os.Bundle;

import com.example.toolbar.R;
import com.example.toolbar.databinding.ActivityToolbar4Binding;

import androidx.appcompat.app.AppCompatActivity;
import androidx.fragment.app.FragmentTransaction;

/***
 * 溢出菜单弹出框：显示图标+文字
 */
public class Toolbar4Activity extends AppCompatActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        ActivityToolbar4Binding binding = ActivityToolbar4Binding.inflate(getLayoutInflater());
        setContentView(binding.getRoot());
        IconFragment1 iconFragment1 = new IconFragment1();
        FragmentTransaction transaction = getSupportFragmentManager().beginTransaction();
        transaction.add(R.id.toolbar4_container, iconFragment1);
        transaction.commit();
    }
}